import request from '@/utils/request.js'
const PATH = '/admin/remark'

// 分页查询评论列表
export const getRemarkList = ({ page, pageSize, type, courseId, userId }) => {
  return request.get(PATH + '/pageQueryRemark', {
    params: {
      page,
      pageSize,
      type,
      courseId,
      userId
    }
  })
}

// 删除评论
export const batchDeleteRemark = (ids) => {
  return request.delete(PATH + '/batchDelete', {
    params: {
      ids: ids.join(',')
    }
  })
}

// 获取评论的用户
export const getRemarkUser = ({ courseId, type }) => {
  return request.get(PATH + '/queryUserName', {
    params: {
      courseId,
      type
    }
  })
}
